x86/mm/p2m: fix pod locking
authorAndres Lagar-Cavilla <andres@lagarcavilla.org>
Thu, 24 Nov 2011 15:20:57 +0000 (15:20 +0000)
committerAndres Lagar-Cavilla <andres@lagarcavilla.org>
Thu, 24 Nov 2011 15:20:57 +0000 (15:20 +0000)
commit85826188d83ea040c55cfe1e3d92d8626c3e3c3d
tree383f4259e53d9cb017c987c22c649266ac3f8600
parentd0d0ded0b6e45882eb2478179c222bdad56a300a
x86/mm/p2m: fix pod locking

The path p2m-lookup -> p2m-pt->get_entry -> 1GB PoD superpage ->
pod_demand_populate ends in the pod code performing a p2m_set_entry with
no locks held (in order to split the 1GB superpage into 512 2MB ones)

Further, it calls p2m_unlock after that, which will break the spinlock.

This patch attempts to fix that.

Signed-off-by: Andres Lagar-Cavilla <andres@lagarcavilla.org>
Acked-by: George Dunlap <george.dunlap@eu.citrix.com>
Acked-by: Tim Deegan <tim@xen.org>
Committed-by: Tim Deegan <tim@xen.org>
xen/arch/x86/mm/p2m-pod.c
xen/arch/x86/mm/p2m-pt.c